﻿using System;
using System.Text;
using System.Collections.Generic;
using Demo_G.O.S.E.ServerEngine.Timer;

namespace Demo_G.O.S.E.ServerEngine.Creature.General
{
    /// <summary>
    /// 
    /// </summary>
    internal class FrozenTimer : TimeSlice
    {
        #region zh-CHS 私有成员变量 | en Private Member Variables
        /// <summary>
        /// 
        /// </summary>
        private GeneralMobile m_Mobile;
        #endregion

        #region zh-CHS 构造和初始化和清理 | en Constructors and Initializers and Dispose
        /// <summary>
        /// 
        /// </summary>
        /// <param name="generalMobile"></param>
        /// <param name="duration"></param>
        public FrozenTimer( GeneralMobile generalMobile, TimeSpan duration )
            : base( duration )
        {
            this.Priority = TimerPriority.TwentyFiveMS;
            m_Mobile = generalMobile;
        }
        #endregion

        #region zh-CHS 保护方法 | en Protected Methods
        /// <summary>
        /// 
        /// </summary>
        protected override void OnTick()
        {
            m_Mobile.Frozen = false;
        }
        #endregion
    }
}

